#pragma once
#ifndef M_PI
#define M_PI 3.14159265358979323846
#endif
#ifndef M_PI_2
#define M_PI_2 3.14159265358979323846/2.0
#endif

#include <qobject.h>
#include "qgsmapcanvas.h"
#include <string>
using std::string;
#include "qgsadvanceddigitizingdockwidget.h"
#include "qgsmaptooldigitizefeature.h"
#include "qgsmemoryproviderutils.h"
#include "qgsgrouplayer.h"
#include <vector>
using std::vector;
#include "PluginData.h"


struct PluginData;

class TestCallback2 : public QObject
{
	Q_OBJECT
public:
	TestCallback2() {
		_mapCanvas = 0;   
		_adWidget = 0; _memVecLayer = 0; _digitizeTool = 0;
		_pluginData = 0;
	}
	~TestCallback2();
	QgsMapCanvas* _mapCanvas;
	

public slots:
	void onAddButton();
	void onClearButton();
	void onSlider(int val);
	void onDrawROI();
	void onUsePlugin();
	void onSave();
	void onDelRoi();
	//digitize tool
	void onDigitizingCanceled();
	void onDigitizingCompleted(const QgsFeature& feature);
	void onDdigitizingFinished();
	//digitize tool end

private:
	QgsAdvancedDigitizingDockWidget* _adWidget;
	QgsVectorLayer* _memVecLayer;
	QgsMapToolDigitizeFeature* _digitizeTool;


	//plugin simulator
private:
	PluginData* _pluginData;

};
